package com.bdy.lm.servlet;

import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

public class AndroidServlet extends HttpServlet {


	public void doGet(HttpServletRequest request, HttpServletResponse response)
			throws ServletException, IOException {
		response.setContentType("text/html;charset=utf-8");
		response.getWriter().println("这是乱码");
		
		response.getWriter().println("get");
		
		System.out.println("访问李明Get");
	}

	public void doPost(HttpServletRequest request, HttpServletResponse response)
			throws ServletException, IOException {
 
		response.setContentType("application/Json;charset=utf-8");
		
		response.getWriter().println("post");
		System.out.println("访问李明Post");
		response.getWriter()
		.print("{\"num\":17,\"messageID\":10,\"messageBodayInt\":0,\"flagBitBegin\":126,\"checkCode\":218,\"ISUFlag_device_3\":0,\"flagBitEnd\":126,\"ISUFlag_company_2\":16,\"ISUFlag_1\":16,\"ISUFlag_serialNum_4\":10526880,\"ICID\":\"19 58 DD CE1\",\"driverName\":\"李明\",\"driverCompany\":\"福建***出租车公司\",\"messageBodyString\":\"8120\"}");
		
	}

}
